package models

import (
	"time"

	. "gddgame.cc/galaxy/common/dsl/db"
	"gddgame.cc/galaxy/utils/orm"
)

var (
	AppLeaderboardUserModel = orm.NewModel("app_leaderboard_user", &AppLeaderboardUser{}, nil)
)

func init() {
	AddTable(&Table{
		Model: AppLeaderboardUserModel,
	})
}

type AppLeaderboardUser struct {
	Id            int `json:"id" orm:"auto" sql:"INT"`
	AppId         int `json:"app_id" sql:"INT"`
	UserId        int `json:"user_id" sql:"INT"`
	LeaderboardId int `json:"leaderboard_id" sql:"INT"`
	Value         int `json:"value" sql:"INT"`

	CreateTime *time.Time `json:"create_time" orm:"createTime" sql:"DATETIME"`
	UpdateTime *time.Time `json:"update_time" orm:"updateTime" sql:"DATETIME"`
}
